function visibleResult(data){
    if(data == 'Success'){
        $('.tipBox').append(` <div class="alert alert-success" style="width:20%; margin-left:40%">
                                         <i class="glyphicon glyphicon-ok"></i> <strong class="msg"></strong>
                                   </div>`) ;
    }else {
        $('.tipBox').append(`<div class="alert alert-danger" style="width:20%; margin-left:40%">
                                        <i class="glyphicon glyphicon-remove"></i> <strong class="msg"></strong>
                                  </div>`);
    }
    $('.msg').text(data == 'Success' ? 'Add successfully!' : data == 'product repeat' ? data : 'Add failed!');

    setTimeout(() => { $('.tipBox').empty(); },3000);
}
